package com.ruoyi.common.utils;

import java.lang.annotation.Annotation;
import java.lang.reflect.Method;

public class AnnotationUtils
{
    public static Object getAnnotationValue(Annotation annotation, String attributeName) throws Exception {
        Class<? extends Annotation> annotationType = annotation.annotationType();
        Method method = annotationType.getDeclaredMethod(attributeName);
        return method.invoke(annotation);
    }
}
